AC_PREREQ(2.59)
AC_INIT([gmediadb],[0.6])
AC_CONFIG_SRCDIR([gmediadb/gmediadb.c])
AM_INIT_AUTOMAKE([dist-bzip2])
CFLAGS="$CFLAGS -g"
AC_PROG_CC
AC_PROG_INSTALL
AC_PROG_LIBTOOL

AC_CONFIG_MACRO_DIR([m4])

PKG_CHECK_MODULES(GLIB, glib-2.0 gthread-2.0)
AC_SUBST(GLIB_CFLAGS)
AC_SUBST(GLIB_LIBS)

PKG_CHECK_MODULES(DBUS, dbus-1 >= 0.60 dbus-glib-1 >= 0.60)
AC_SUBST(DBUS_CFLAGS)
AC_SUBST(DBUS_LIBS)

PKG_CHECK_MODULES(SQLITE, sqlite3)
AC_SUBST(SQLITE_CFLAGS)
AC_SUBST(SQLITE_LIBS)

AC_PATH_PROG(DBUSBINDINGTOOL, dbus-binding-tool)
AC_SUBST(DBUSBINDINGTOOL)

AC_OUTPUT([
Makefile
gmediadb/Makefile
gmediadb/gmediadb.pc
dbus-server/Makefile
])
